Lighting systems often comprise a plurality of lighting devices adapted to illuminate an area, and light switches or other control devices for controlling the illumination provided by the lighting devices. In such lighting systems, the lighting devices may be arranged in groups, e.g., associated with different rooms, each group being controllable by light switches in the corresponding room. The grouping of the lighting devices may be performed by connecting the appropriate lighting devices to the corresponding light switch, e.g., by wires or by using wireless communication. Forming such connections may be cumbersome and/or time consuming, especially if the number of lighting devices is large. Moreover, if lighting devices or light switches are moved or replaced later on, new groups may have to be formed by making new connections. Hence, it would be desirable to provide easier, more flexible, and/or less time consuming ways of grouping lighting devices in a lighting system.